import 'package:flutter/material.dart';

///
/// Card API : https://api.flutter-io.cn/flutter/material/Card-class.html
///
class DemoCard extends StatelessWidget {
  const DemoCard({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Column 布局',
      home: Scaffold(
        appBar: AppBar(
            title: const Text('垂直方向布局')
        ),
        body: const MyCard01(),
      ),
    );
  }
}

///
/// Divider, 为什么没有效果呢？
///

class MyCard01 extends StatelessWidget {
  const MyCard01({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    var card = Card(
      child: Column(
        children: const [
          ListTile(
            title: Text('吉林省吉林市昌邑区', style: TextStyle(fontWeight: FontWeight.w500),),
            subtitle: Text('技术胖:15139388898'),
            leading: Icon(Icons.account_box, color: Colors.lightBlue),
          ),
          Divider(color: Colors.black, height: 10.0,),
          ListTile(
            title: Text('吉林省吉林市昌邑区', style: TextStyle(fontWeight: FontWeight.w500),),
            subtitle: Text('技术胖:15139388898'),
            leading: Icon(Icons.account_box, color: Colors.lightBlue),
          ),
          // Divider(color: Colors.black, height: 10.0),
          ListTile(
            title: Text('吉林省吉林市昌邑区', style: TextStyle(fontWeight: FontWeight.w500),),
            subtitle: Text('技术胖:15139388898'),
            leading: Icon(Icons.account_box, color: Colors.lightBlue),
          ),
          Divider(color: Colors.black, height: 10.0,),
        ],
      ),
    );
    return Center(
      child: card,
    );
  }

}

